home *** CD-ROM | disk | FTP | other *** search
- Path: clients1.news.internex.net!usenet
- From: Paul Meyer <pem@radmedia.com>
- Newsgroups: comp.os.ms-windows.programmer.tools.winsock,comp.lang.c++,comp.os.ms-windows.programmer.tools.misc
- Subject: Re: DDE, C++ and ILOG VIEWS
- Date: Tue, 16 Apr 1996 13:34:40 -0700
- Organization: RadMedia, Inc.
- Message-ID: <31740460.44FE@radmedia.com>
- References: <4kljqu$ekf@news.cea.fr>
- NNTP-Posting-Host: 205.158.20.71
- Mime-Version: 1.0
- Content-Type: text/plain; charset=us-ascii
- Content-Transfer-Encoding: 7bit
- X-Mailer: Mozilla 2.0 (WinNT; I)
-
- Buteau wrote:
- > Has somebody written some classes that encapsulate the DDE mechanism??
- >
- > (I mean a class like DDEclient that you can derive from, and that has
- > member functions like send, receive, poke ....)
-
- Errr, yes, but it was in the scope of a previous job and thus not suitable
- for publication (and in fact I don't have a copy).
-
- OTOH it only took me about a week to do the whole thing. Then again, I've
- been using C++ since cfront 1.2 so I'm a bit familiar with class design.
-
- The real trick is in allowing for the callbacks. DDE is not useful for
- nontrivial things unless you use an asynchronous approach. Probably the
- easiest design to use is to make the callback function dispatch to several
- virtual member functions based on what it gets for parameters. There is
- also the problem of deciding which DDE object should get the callback if
- you instantiate more than one. I tried using the DDE provision for attaching
- a user datum to a conversation, but it turns out that some important callbacks
- occur in situations where that datum is not available. I had to fall back
- to a runtime lookup table scheme. If you don't need more than one DDE object
- in a program, though, this doesn't come up.
-
- --
- Paul Meyer | When the Tremere ask you about your style of
- pem@radmedia.com | magic, just feel really confident and say,
- pem@amurgsval.org | "These aren't the Druids you're looking for."
-